import request from '@/utils/request'

// 查询商品相册列表
export function listGallery(query) {
  return request({
    url: '/product/gallery/list',
    method: 'get',
    params: query
  })
}

// 查询商品相册详细
export function getGallery(id) {
  return request({
    url: '/product/gallery/' + id,
    method: 'get'
  })
}

// 新增商品相册
export function addGallery(data) {
  return request({
    url: '/product/gallery',
    method: 'post',
    data: data
  })
}

// 修改商品相册
export function updateGallery(data) {
  return request({
    url: '/product/gallery',
    method: 'put',
    data: data
  })
}

// 删除商品相册
export function delGallery(id) {
  return request({
    url: '/product/gallery/' + id,
    method: 'delete'
  })
}
